package kompics.pp;

import se.sics.kompics.launch.Scenario;
import se.sics.kompics.launch.Topology;

public class PPExecutor {

	
	public static final void main(String[] args) {
		
		Topology topology1 = new Topology() {
			/**
			 * 
			 */
			private static final long serialVersionUID = 1L;

			{
				node(1, "127.0.0.1", 22031);
				node(2, "127.0.0.1", 22032);
				node(3, "127.0.0.1", 22033);
				node(4, "127.0.0.1", 22034);
				link(1, 2, 0, 0.5).bidirectional();
				link(1, 3, 0, 0.5).bidirectional();
				link(1, 4, 0, 0.5).bidirectional();
				defaultLinks(1000, 0);
				// link(1, 2, 0, 0.99).bidirectional();
			}
		};

		
		Scenario scenario1 = 
		new Scenario(MainContainer.class) {
			{
				command(1, "3000");
				command(2, "2000");
				command(3, "3000");
				command(4, "2000");
			}
		};

	
		scenario1.executeOn(topology1);
		try{Thread.sleep(100000);}catch(Exception e) {}
		System.exit(0);
	}
}
